<?php 
$config = new Zend_Config_Ini(APPLICATION_PATH. '/configs/config.ini',APPLICATION_ENV);
?>
<html>
    <head>
        <title>正在为您跳转到Paypal进行支付...</title>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
    </head>
    <body>
        <div>正在为您跳转到Paypal进行支付...</div>
         <form action="<?= $config->paypalurl ?>" method="post">
            <input type="hidden" name="business" value="<?= $config->account ?>">
            <input type="hidden" name="item_name" value="<?= $this->itemname ?>">
            <input type="hidden" name="amount" value="<?= number_format($this->bill->Usmoney,2) ?>">
            <input type="hidden" name="no_note" value="1">
            <input type="hidden" name="return"  value="<?= $config->host.'/Pay/success/pid/'.$this->bill->Id ?>">
            <input type="hidden" name="cancel_return" value="<?= $config->host.'/Pay/Cancel?pid='.$this->bill->Id ?>">
            <input type="hidden" name="custom" value="1">
            <input type="hidden" name="notify_url" value="<?= $config->host.'/Pay/Notify?pid='.$this->bill->Id ?>">
            <input type="hidden" name="cmd" value="_xclick">
            <input type="hidden" name="currency_code" value="USD">
            <input type="hidden" name="charset" value="utf-8" />
            <input type="hidden" name="rm" value="1" />
            <input type="submit" id="pay" value="支付" style="display:none" />
        </form>
    </body>
    <script type="text/javascript">
        setTimeout(function(){
            document.getElementById('pay').click();
        },0);
    </script>
</html>